#define _CRT_SECURE_NO_WARNINGS 1

#include<iostream>
#include "BitSet.h"
#include "twoBitSet.h"

void TestBitSet1()
{
	zhang::bitset<100> bst;

	bst.set(8);
	bst.set(10);
	bst.set(20);

	std::cout << bst.test(8) << std::endl;
	std::cout << bst.test(10) << std::endl;
	std::cout << bst.test(20) << std::endl;

	bst.reset(8);
	bst.reset(10);
	bst.reset(15);
	bst.reset(20);

	std::cout << bst.test(8) << std::endl;
	std::cout << bst.test(10) << std::endl;
	std::cout << bst.test(20) << std::endl;
}


void TestBitSet2()
{
	size_t arr[] = { 33,12,33,56,23,44,44,33,12,8,45,45,6,7,98,99,23 };
	
	zhang::two_bitset<100> two_bst;
	for (auto e : arr)
	{
		two_bst.set(e);
	}

	two_bst.PrintOnceNum();
}


void TestBitSet3()
{
	size_t arr[] = { 0,0,1,1,1,3,3,5,6,7,7,7,7,8,8,8,11,13,15,15 };

	zhang::two_bitset<15> two_bst;
	for (auto e : arr)
	{
		two_bst.set(e);
	}

	two_bst.PrintNotMoreThanTwo();
}


int main()
{
	TestBitSet3();
	return 0;
}